package com.hll.demo.controller;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;

/*@RestController  如果要返回JSON数据就加，要不然就在每个方法前面加 @ResponseBody*/
@Controller /*跳转页面就加这个*/
public class HelloController {

  @RequestMapping("/index") // localhost:port/index
  public String sayHello() {
    return "index"; // templcates/index.html
  }
}
